public class CoarseGrainedObject {
    DependentObject1 object1;
    DependentObject2 object2;

    public CoarseGrainedObject(){
        this.object1 = new DependentObject1();
        this.object2 = new DependentObject2();
    }

    public void setData(String string1,String string2){
        object1.setData(string1);
        object2.setData(string2);
    }

    public String[] getData(){
        return new String[]{object1.getData(),object2.getData()};
    }
}
